#ifndef _BSP_BLUFI_H
#define _BSP_BLUFI_H

#include "esp_err.h"
#include "esp_blufi_api.h"
#ifdef CONFIG_BT_BLUEDROID_ENABLED
#include "esp_bt.h"
#include "esp_bt_main.h"
#include "esp_bt_device.h"
#endif
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "freertos/FreeRTOS.h"
#include "freertos/task.h"
#include "freertos/event_groups.h"
#include "esp_system.h"
#include "esp_mac.h"
#include "esp_wifi.h"
#include "esp_event.h"
#include "esp_log.h"
#include "nvs_flash.h"
#include "esp_blufi.h"
#include "bsp_blufi_security.h"



#define EXAMPLE_WIFI_CONNECTION_MAXIMUM_RETRY CONFIG_EXAMPLE_WIFI_CONNECTION_MAXIMUM_RETRY
#define EXAMPLE_INVALID_REASON                255
#define EXAMPLE_INVALID_RSSI                  -128
#define WIFI_LIST_NUM   10
















extern bool gl_sta_got_ip;




esp_err_t esp_blufi_host_deinit(void);
esp_err_t esp_blufi_host_and_cb_init(esp_blufi_callbacks_t *callbacks);
esp_err_t esp_blufi_host_init(void);
int esp_blufi_gap_register_callback(void);

void blufi_init(void);

void ble_registration_json_send(void);
void ble_ack_json_send(char* buffer);
void ble_report_json_send(void *send_data);
void ble_parse_rx_data(char *buffer);

#endif
